\hypertarget{group__timer__api}{
\section{Timer\_\-api}
\label{group__timer__api}\index{Timer\_\-api@{Timer\_\-api}}
}
\subsection*{Functions}
\begin{DoxyCompactItemize}
\item 
void \hyperlink{group__timer__api_ga81abc6c869af19af41fef1234b0aa37b}{TimerEnable} (unsigned long ulBase, unsigned long ulTimer)
\item 
void \hyperlink{group__timer__api_ga45b8bb296557001690d8e7aecca814ef}{TimerDisable} (unsigned long ulBase, unsigned long ulTimer)
\item 
void \hyperlink{group__timer__api_gaf511aa75837b9611590bba0e83c4aefa}{TimerConfigure} (unsigned long ulBase, unsigned long ulConfig)
\item 
void \hyperlink{group__timer__api_ga0115ebae8bd7d7e8ffabcd01ab25682a}{TimerControlLevel} (unsigned long ulBase, unsigned long ulTimer, tBoolean bInvert)
\item 
void \hyperlink{group__timer__api_gae1552db4e66ccf599748b7adaa4fbd21}{TimerControlTrigger} (unsigned long ulBase, unsigned long ulTimer, tBoolean bEnable)
\item 
void \hyperlink{group__timer__api_gaf33f5cf88d5499ba8d56860698236ce7}{TimerControlEvent} (unsigned long ulBase, unsigned long ulTimer, unsigned long ulEvent)
\item 
void \hyperlink{group__timer__api_ga19213127b6004ce2dce2fd443a6d2517}{TimerControlStall} (unsigned long ulBase, unsigned long ulTimer, tBoolean bStall)
\item 
void \hyperlink{group__timer__api_ga43e89e7a1ce13e8b6b33f557819749c2}{TimerRTCEnable} (unsigned long ulBase)
\item 
void \hyperlink{group__timer__api_ga0026845c00f07517b05c37638f835731}{TimerRTCDisable} (unsigned long ulBase)
\item 
void \hyperlink{group__timer__api_ga7cf851124da7d14993aad51ce89b3a70}{TimerPrescaleSet} (unsigned long ulBase, unsigned long ulTimer, unsigned long ulValue)
\item 
unsigned long \hyperlink{group__timer__api_ga6ccd45b12141c58c580ebdf3f5a2d3df}{TimerPrescaleGet} (unsigned long ulBase, unsigned long ulTimer)
\item 
void \hyperlink{group__timer__api_ga44faa8d49da187e7b17f960c7078403e}{TimerLoadSet} (unsigned long ulBase, unsigned long ulTimer, unsigned long ulValue)
\item 
unsigned long \hyperlink{group__timer__api_ga3387d54ad7851b6194409eee5c3204ff}{TimerLoadGet} (unsigned long ulBase, unsigned long ulTimer)
\item 
unsigned long \hyperlink{group__timer__api_ga6c5cb6601369fdd2a03b5b63699ade8d}{TimerValueGet} (unsigned long ulBase, unsigned long ulTimer)
\item 
void \hyperlink{group__timer__api_gaa3700e1bbef47e74a755371190223a39}{TimerMatchSet} (unsigned long ulBase, unsigned long ulTimer, unsigned long ulValue)
\item 
unsigned long \hyperlink{group__timer__api_ga9fa5aca88900e80db7d60109d4143bb9}{TimerMatchGet} (unsigned long ulBase, unsigned long ulTimer)
\item 
void \hyperlink{group__timer__api_ga798bb0baddba9a19b4dc22a52253f4b4}{TimerIntRegister} (unsigned long ulBase, unsigned long ulTimer, void($\ast$pfnHandler)(void))
\item 
void \hyperlink{group__timer__api_ga8db4e2b8aa6303596471645c5496d557}{TimerIntUnregister} (unsigned long ulBase, unsigned long ulTimer)
\item 
void \hyperlink{group__timer__api_ga3910c5b44f9b267dff9c7a3fb3851610}{TimerIntEnable} (unsigned long ulBase, unsigned long ulIntFlags)
\item 
void \hyperlink{group__timer__api_ga289807d37680c8c4475d154f2d863914}{TimerIntDisable} (unsigned long ulBase, unsigned long ulIntFlags)
\item 
unsigned long \hyperlink{group__timer__api_ga95bc8954661b4e554bdfa2377f36d1af}{TimerIntStatus} (unsigned long ulBase, tBoolean bMasked)
\item 
void \hyperlink{group__timer__api_gaab68a69784ee1b3288d9cb6b01ca6ec7}{TimerIntClear} (unsigned long ulBase, unsigned long ulIntFlags)
\item 
\hypertarget{group__timer__api_gad18bc45c7f42731ffec42dcabe2422a3}{
void {\bfseries TimerQuiesce} (unsigned long ulBase)}
\label{group__timer__api_gad18bc45c7f42731ffec42dcabe2422a3}

\end{DoxyCompactItemize}


\subsection{Function Documentation}
\hypertarget{group__timer__api_gaf511aa75837b9611590bba0e83c4aefa}{
\index{timer\_\-api@{timer\_\-api}!TimerConfigure@{TimerConfigure}}
\index{TimerConfigure@{TimerConfigure}!timer_api@{timer\_\-api}}
\subsubsection[{TimerConfigure}]{\setlength{\rightskip}{0pt plus 5cm}void TimerConfigure (
\begin{DoxyParamCaption}
\item[{unsigned long}]{ ulBase, }
\item[{unsigned long}]{ ulConfig}
\end{DoxyParamCaption}
)}}
\label{group__timer__api_gaf511aa75837b9611590bba0e83c4aefa}
Configures the timer(s).


\begin{DoxyParams}{Parameters}
\item[{\em ulBase}]is the base address of the timer module. \item[{\em ulConfig}]is the configuration for the timer.\end{DoxyParams}
This function configures the operating mode of the timer(s). The timer module is disabled before being configured, and is left in the disabled state. The configuration is specified in {\itshape ulConfig\/} as one of the following values:


\begin{DoxyItemize}
\item {\bfseries TIMER\_\-CFG\_\-32\_\-BIT\_\-OS} -\/ 32-\/bit one shot timer
\item {\bfseries TIMER\_\-CFG\_\-32\_\-BIT\_\-PER} -\/ 32-\/bit periodic timer
\item {\bfseries TIMER\_\-CFG\_\-32\_\-RTC} -\/ 32-\/bit real time clock timer
\item {\bfseries TIMER\_\-CFG\_\-16\_\-BIT\_\-PAIR} -\/ Two 16-\/bit timers
\end{DoxyItemize}

When configured for a pair of 16-\/bit timers, each timer is separately configured. The first timer is configured by setting {\itshape ulConfig\/} to the result of a logical OR operation between one of the following values and {\itshape ulConfig:\/} 


\begin{DoxyItemize}
\item {\bfseries TIMER\_\-CFG\_\-A\_\-ONE\_\-SHOT} -\/ 16-\/bit one shot timer
\item {\bfseries TIMER\_\-CFG\_\-A\_\-PERIODIC} -\/ 16-\/bit periodic timer
\item {\bfseries TIMER\_\-CFG\_\-A\_\-CAP\_\-COUNT} -\/ 16-\/bit edge count capture
\item {\bfseries TIMER\_\-CFG\_\-A\_\-CAP\_\-TIME} -\/ 16-\/bit edge time capture
\item {\bfseries TIMER\_\-CFG\_\-A\_\-PWM} -\/ 16-\/bit PWM output
\end{DoxyItemize}

Similarly, the second timer is configured by setting {\itshape ulConfig\/} to the result of a logical OR operation between one of the corresponding {\bfseries TIMER\_\-CFG\_\-B\_\-$\ast$} values and {\itshape ulConfig\/}.

\begin{DoxyReturn}{Returns}
None. 
\end{DoxyReturn}
\hypertarget{group__timer__api_gaf33f5cf88d5499ba8d56860698236ce7}{
\index{timer\_\-api@{timer\_\-api}!TimerControlEvent@{TimerControlEvent}}
\index{TimerControlEvent@{TimerControlEvent}!timer_api@{timer\_\-api}}
\subsubsection[{TimerControlEvent}]{\setlength{\rightskip}{0pt plus 5cm}void TimerControlEvent (
\begin{DoxyParamCaption}
\item[{unsigned long}]{ ulBase, }
\item[{unsigned long}]{ ulTimer, }
\item[{unsigned long}]{ ulEvent}
\end{DoxyParamCaption}
)}}
\label{group__timer__api_gaf33f5cf88d5499ba8d56860698236ce7}
Controls the event type.


\begin{DoxyParams}{Parameters}
\item[{\em ulBase}]is the base address of the timer module. \item[{\em ulTimer}]specifies the timer(s) to be adjusted; must be one of {\bfseries TIMER\_\-A}, {\bfseries TIMER\_\-B}, or {\bfseries TIMER\_\-BOTH}. \item[{\em ulEvent}]specifies the type of event; must be one of {\bfseries TIMER\_\-EVENT\_\-POS\_\-EDGE}, {\bfseries TIMER\_\-EVENT\_\-NEG\_\-EDGE}, or {\bfseries TIMER\_\-EVENT\_\-BOTH\_\-EDGES}.\end{DoxyParams}
This function sets the signal edge(s) that will trigger the timer when in capture mode.

\begin{DoxyReturn}{Returns}
None. 
\end{DoxyReturn}
\hypertarget{group__timer__api_ga0115ebae8bd7d7e8ffabcd01ab25682a}{
\index{timer\_\-api@{timer\_\-api}!TimerControlLevel@{TimerControlLevel}}
\index{TimerControlLevel@{TimerControlLevel}!timer_api@{timer\_\-api}}
\subsubsection[{TimerControlLevel}]{\setlength{\rightskip}{0pt plus 5cm}void TimerControlLevel (
\begin{DoxyParamCaption}
\item[{unsigned long}]{ ulBase, }
\item[{unsigned long}]{ ulTimer, }
\item[{tBoolean}]{ bInvert}
\end{DoxyParamCaption}
)}}
\label{group__timer__api_ga0115ebae8bd7d7e8ffabcd01ab25682a}
Controls the output level.


\begin{DoxyParams}{Parameters}
\item[{\em ulBase}]is the base address of the timer module. \item[{\em ulTimer}]specifies the timer(s) to adjust; must be one of {\bfseries TIMER\_\-A}, {\bfseries TIMER\_\-B}, or {\bfseries TIMER\_\-BOTH}. \item[{\em bInvert}]specifies the output level.\end{DoxyParams}
This function sets the PWM output level for the specified timer. If the {\itshape bInvert\/} parameter is {\bfseries true}, then the timer's output will be made active low; otherwise, it will be made active high.

\begin{DoxyReturn}{Returns}
None. 
\end{DoxyReturn}
\hypertarget{group__timer__api_ga19213127b6004ce2dce2fd443a6d2517}{
\index{timer\_\-api@{timer\_\-api}!TimerControlStall@{TimerControlStall}}
\index{TimerControlStall@{TimerControlStall}!timer_api@{timer\_\-api}}
\subsubsection[{TimerControlStall}]{\setlength{\rightskip}{0pt plus 5cm}void TimerControlStall (
\begin{DoxyParamCaption}
\item[{unsigned long}]{ ulBase, }
\item[{unsigned long}]{ ulTimer, }
\item[{tBoolean}]{ bStall}
\end{DoxyParamCaption}
)}}
\label{group__timer__api_ga19213127b6004ce2dce2fd443a6d2517}
Controls the stall handling.


\begin{DoxyParams}{Parameters}
\item[{\em ulBase}]is the base address of the timer module. \item[{\em ulTimer}]specifies the timer(s) to be adjusted; must be one of {\bfseries TIMER\_\-A}, {\bfseries TIMER\_\-B}, or {\bfseries TIMER\_\-BOTH}. \item[{\em bStall}]specifies the response to a stall signal.\end{DoxyParams}
This function controls the stall response for the specified timer. If the {\itshape bStall\/} parameter is {\bfseries true}, then the timer will stop counting if the processor enters debug mode; otherwise the timer will keep running while in debug mode.

\begin{DoxyReturn}{Returns}
None. 
\end{DoxyReturn}
\hypertarget{group__timer__api_gae1552db4e66ccf599748b7adaa4fbd21}{
\index{timer\_\-api@{timer\_\-api}!TimerControlTrigger@{TimerControlTrigger}}
\index{TimerControlTrigger@{TimerControlTrigger}!timer_api@{timer\_\-api}}
\subsubsection[{TimerControlTrigger}]{\setlength{\rightskip}{0pt plus 5cm}void TimerControlTrigger (
\begin{DoxyParamCaption}
\item[{unsigned long}]{ ulBase, }
\item[{unsigned long}]{ ulTimer, }
\item[{tBoolean}]{ bEnable}
\end{DoxyParamCaption}
)}}
\label{group__timer__api_gae1552db4e66ccf599748b7adaa4fbd21}
Enables or disables the trigger output.


\begin{DoxyParams}{Parameters}
\item[{\em ulBase}]is the base address of the timer module. \item[{\em ulTimer}]specifies the timer to adjust; must be one of {\bfseries TIMER\_\-A}, {\bfseries TIMER\_\-B}, or {\bfseries TIMER\_\-BOTH}. \item[{\em bEnable}]specifies the desired trigger state.\end{DoxyParams}
This function controls the trigger output for the specified timer. If the {\itshape bEnable\/} parameter is {\bfseries true}, then the timer's output trigger is enabled; otherwise it is disabled.

\begin{DoxyReturn}{Returns}
None. 
\end{DoxyReturn}
\hypertarget{group__timer__api_ga45b8bb296557001690d8e7aecca814ef}{
\index{timer\_\-api@{timer\_\-api}!TimerDisable@{TimerDisable}}
\index{TimerDisable@{TimerDisable}!timer_api@{timer\_\-api}}
\subsubsection[{TimerDisable}]{\setlength{\rightskip}{0pt plus 5cm}void TimerDisable (
\begin{DoxyParamCaption}
\item[{unsigned long}]{ ulBase, }
\item[{unsigned long}]{ ulTimer}
\end{DoxyParamCaption}
)}}
\label{group__timer__api_ga45b8bb296557001690d8e7aecca814ef}
Disables the timer(s).


\begin{DoxyParams}{Parameters}
\item[{\em ulBase}]is the base address of the timer module. \item[{\em ulTimer}]specifies the timer(s) to disable; must be one of {\bfseries TIMER\_\-A}, {\bfseries TIMER\_\-B}, or {\bfseries TIMER\_\-BOTH}.\end{DoxyParams}
This will disable operation of the timer module.

\begin{DoxyReturn}{Returns}
None. 
\end{DoxyReturn}
\hypertarget{group__timer__api_ga81abc6c869af19af41fef1234b0aa37b}{
\index{timer\_\-api@{timer\_\-api}!TimerEnable@{TimerEnable}}
\index{TimerEnable@{TimerEnable}!timer_api@{timer\_\-api}}
\subsubsection[{TimerEnable}]{\setlength{\rightskip}{0pt plus 5cm}void TimerEnable (
\begin{DoxyParamCaption}
\item[{unsigned long}]{ ulBase, }
\item[{unsigned long}]{ ulTimer}
\end{DoxyParamCaption}
)}}
\label{group__timer__api_ga81abc6c869af19af41fef1234b0aa37b}
Enables the timer(s).


\begin{DoxyParams}{Parameters}
\item[{\em ulBase}]is the base address of the timer module. \item[{\em ulTimer}]specifies the timer(s) to enable; must be one of {\bfseries TIMER\_\-A}, {\bfseries TIMER\_\-B}, or {\bfseries TIMER\_\-BOTH}.\end{DoxyParams}
This will enable operation of the timer module. The timer must be configured before it is enabled.

\begin{DoxyReturn}{Returns}
None. 
\end{DoxyReturn}
\hypertarget{group__timer__api_gaab68a69784ee1b3288d9cb6b01ca6ec7}{
\index{timer\_\-api@{timer\_\-api}!TimerIntClear@{TimerIntClear}}
\index{TimerIntClear@{TimerIntClear}!timer_api@{timer\_\-api}}
\subsubsection[{TimerIntClear}]{\setlength{\rightskip}{0pt plus 5cm}void TimerIntClear (
\begin{DoxyParamCaption}
\item[{unsigned long}]{ ulBase, }
\item[{unsigned long}]{ ulIntFlags}
\end{DoxyParamCaption}
)}}
\label{group__timer__api_gaab68a69784ee1b3288d9cb6b01ca6ec7}
Clears timer interrupt sources.


\begin{DoxyParams}{Parameters}
\item[{\em ulBase}]is the base address of the timer module. \item[{\em ulIntFlags}]is a bit mask of the interrupt sources to be cleared.\end{DoxyParams}
The specified timer interrupt sources are cleared, so that they no longer assert. This must be done in the interrupt handler to keep it from being called again immediately upon exit.

The {\itshape ulIntFlags\/} parameter has the same definition as the {\itshape ulIntFlags\/} parameter to \hyperlink{group__timer__api_ga3910c5b44f9b267dff9c7a3fb3851610}{TimerIntEnable()}.

\begin{DoxyNote}{Note}
Since there is a write buffer in the Cortex-\/M3 processor, it may take several clock cycles before the interrupt source is actually cleared. Therefore, it is recommended that the interrupt source be cleared early in the interrupt handler (as opposed to the very last action) to avoid returning from the interrupt handler before the interrupt source is actually cleared. Failure to do so may result in the interrupt handler being immediately reentered (since NVIC still sees the interrupt source asserted).
\end{DoxyNote}
\begin{DoxyReturn}{Returns}
None. 
\end{DoxyReturn}
\hypertarget{group__timer__api_ga289807d37680c8c4475d154f2d863914}{
\index{timer\_\-api@{timer\_\-api}!TimerIntDisable@{TimerIntDisable}}
\index{TimerIntDisable@{TimerIntDisable}!timer_api@{timer\_\-api}}
\subsubsection[{TimerIntDisable}]{\setlength{\rightskip}{0pt plus 5cm}void TimerIntDisable (
\begin{DoxyParamCaption}
\item[{unsigned long}]{ ulBase, }
\item[{unsigned long}]{ ulIntFlags}
\end{DoxyParamCaption}
)}}
\label{group__timer__api_ga289807d37680c8c4475d154f2d863914}
Disables individual timer interrupt sources.


\begin{DoxyParams}{Parameters}
\item[{\em ulBase}]is the base address of the timer module. \item[{\em ulIntFlags}]is the bit mask of the interrupt sources to be disabled.\end{DoxyParams}
Disables the indicated timer interrupt sources. Only the sources that are enabled can be reflected to the processor interrupt; disabled sources have no effect on the processor.

The {\itshape ulIntFlags\/} parameter has the same definition as the {\itshape ulIntFlags\/} parameter to \hyperlink{group__timer__api_ga3910c5b44f9b267dff9c7a3fb3851610}{TimerIntEnable()}.

\begin{DoxyReturn}{Returns}
None. 
\end{DoxyReturn}
\hypertarget{group__timer__api_ga3910c5b44f9b267dff9c7a3fb3851610}{
\index{timer\_\-api@{timer\_\-api}!TimerIntEnable@{TimerIntEnable}}
\index{TimerIntEnable@{TimerIntEnable}!timer_api@{timer\_\-api}}
\subsubsection[{TimerIntEnable}]{\setlength{\rightskip}{0pt plus 5cm}void TimerIntEnable (
\begin{DoxyParamCaption}
\item[{unsigned long}]{ ulBase, }
\item[{unsigned long}]{ ulIntFlags}
\end{DoxyParamCaption}
)}}
\label{group__timer__api_ga3910c5b44f9b267dff9c7a3fb3851610}
Enables individual timer interrupt sources.


\begin{DoxyParams}{Parameters}
\item[{\em ulBase}]is the base address of the timer module. \item[{\em ulIntFlags}]is the bit mask of the interrupt sources to be enabled.\end{DoxyParams}
Enables the indicated timer interrupt sources. Only the sources that are enabled can be reflected to the processor interrupt; disabled sources have no effect on the processor.

The {\itshape ulIntFlags\/} parameter must be the logical OR of any combination of the following:


\begin{DoxyItemize}
\item {\bfseries TIMER\_\-CAPB\_\-EVENT} -\/ Capture B event interrupt
\item {\bfseries TIMER\_\-CAPB\_\-MATCH} -\/ Capture B match interrupt
\item {\bfseries TIMER\_\-TIMB\_\-TIMEOUT} -\/ Timer B timeout interrupt
\item {\bfseries TIMER\_\-RTC\_\-MATCH} -\/ RTC interrupt mask
\item {\bfseries TIMER\_\-CAPA\_\-EVENT} -\/ Capture A event interrupt
\item {\bfseries TIMER\_\-CAPA\_\-MATCH} -\/ Capture A match interrupt
\item {\bfseries TIMER\_\-TIMA\_\-TIMEOUT} -\/ Timer A timeout interrupt
\end{DoxyItemize}

\begin{DoxyReturn}{Returns}
None. 
\end{DoxyReturn}
\hypertarget{group__timer__api_ga798bb0baddba9a19b4dc22a52253f4b4}{
\index{timer\_\-api@{timer\_\-api}!TimerIntRegister@{TimerIntRegister}}
\index{TimerIntRegister@{TimerIntRegister}!timer_api@{timer\_\-api}}
\subsubsection[{TimerIntRegister}]{\setlength{\rightskip}{0pt plus 5cm}void TimerIntRegister (
\begin{DoxyParamCaption}
\item[{unsigned long}]{ ulBase, }
\item[{unsigned long}]{ ulTimer, }
\item[{void($\ast$)(void)}]{ pfnHandler}
\end{DoxyParamCaption}
)}}
\label{group__timer__api_ga798bb0baddba9a19b4dc22a52253f4b4}
Registers an interrupt handler for the timer interrupt.


\begin{DoxyParams}{Parameters}
\item[{\em ulBase}]is the base address of the timer module. \item[{\em ulTimer}]specifies the timer(s); must be one of {\bfseries TIMER\_\-A}, {\bfseries TIMER\_\-B}, or {\bfseries TIMER\_\-BOTH}. \item[{\em pfnHandler}]is a pointer to the function to be called when the timer interrupt occurs.\end{DoxyParams}
This sets the handler to be called when a timer interrupt occurs. This will enable the global interrupt in the interrupt controller; specific timer interrupts must be enabled via \hyperlink{group__timer__api_ga3910c5b44f9b267dff9c7a3fb3851610}{TimerIntEnable()}. It is the interrupt handler's responsibility to clear the interrupt source via \hyperlink{group__timer__api_gaab68a69784ee1b3288d9cb6b01ca6ec7}{TimerIntClear()}.

\begin{DoxySeeAlso}{See also}
\hyperlink{group__interrupt__api_ga471d00d73ae22faa426c202f608e9c69}{IntRegister()} for important information about registering interrupt handlers.
\end{DoxySeeAlso}
\begin{DoxyReturn}{Returns}
None. 
\end{DoxyReturn}
\hypertarget{group__timer__api_ga95bc8954661b4e554bdfa2377f36d1af}{
\index{timer\_\-api@{timer\_\-api}!TimerIntStatus@{TimerIntStatus}}
\index{TimerIntStatus@{TimerIntStatus}!timer_api@{timer\_\-api}}
\subsubsection[{TimerIntStatus}]{\setlength{\rightskip}{0pt plus 5cm}unsigned long TimerIntStatus (
\begin{DoxyParamCaption}
\item[{unsigned long}]{ ulBase, }
\item[{tBoolean}]{ bMasked}
\end{DoxyParamCaption}
)}}
\label{group__timer__api_ga95bc8954661b4e554bdfa2377f36d1af}
Gets the current interrupt status.


\begin{DoxyParams}{Parameters}
\item[{\em ulBase}]is the base address of the timer module. \item[{\em bMasked}]is false if the raw interrupt status is required and true if the masked interrupt status is required.\end{DoxyParams}
This returns the interrupt status for the timer module. Either the raw interrupt status or the status of interrupts that are allowed to reflect to the processor can be returned.

\begin{DoxyReturn}{Returns}
The current interrupt status, enumerated as a bit field of values described in \hyperlink{group__timer__api_ga3910c5b44f9b267dff9c7a3fb3851610}{TimerIntEnable()}. 
\end{DoxyReturn}
\hypertarget{group__timer__api_ga8db4e2b8aa6303596471645c5496d557}{
\index{timer\_\-api@{timer\_\-api}!TimerIntUnregister@{TimerIntUnregister}}
\index{TimerIntUnregister@{TimerIntUnregister}!timer_api@{timer\_\-api}}
\subsubsection[{TimerIntUnregister}]{\setlength{\rightskip}{0pt plus 5cm}void TimerIntUnregister (
\begin{DoxyParamCaption}
\item[{unsigned long}]{ ulBase, }
\item[{unsigned long}]{ ulTimer}
\end{DoxyParamCaption}
)}}
\label{group__timer__api_ga8db4e2b8aa6303596471645c5496d557}
Unregisters an interrupt handler for the timer interrupt.


\begin{DoxyParams}{Parameters}
\item[{\em ulBase}]is the base address of the timer module. \item[{\em ulTimer}]specifies the timer(s); must be one of {\bfseries TIMER\_\-A}, {\bfseries TIMER\_\-B}, or {\bfseries TIMER\_\-BOTH}.\end{DoxyParams}
This function will clear the handler to be called when a timer interrupt occurs. This will also mask off the interrupt in the interrupt controller so that the interrupt handler no longer is called.

\begin{DoxySeeAlso}{See also}
\hyperlink{group__interrupt__api_ga471d00d73ae22faa426c202f608e9c69}{IntRegister()} for important information about registering interrupt handlers.
\end{DoxySeeAlso}
\begin{DoxyReturn}{Returns}
None. 
\end{DoxyReturn}
\hypertarget{group__timer__api_ga3387d54ad7851b6194409eee5c3204ff}{
\index{timer\_\-api@{timer\_\-api}!TimerLoadGet@{TimerLoadGet}}
\index{TimerLoadGet@{TimerLoadGet}!timer_api@{timer\_\-api}}
\subsubsection[{TimerLoadGet}]{\setlength{\rightskip}{0pt plus 5cm}unsigned long TimerLoadGet (
\begin{DoxyParamCaption}
\item[{unsigned long}]{ ulBase, }
\item[{unsigned long}]{ ulTimer}
\end{DoxyParamCaption}
)}}
\label{group__timer__api_ga3387d54ad7851b6194409eee5c3204ff}
Gets the timer load value.


\begin{DoxyParams}{Parameters}
\item[{\em ulBase}]is the base address of the timer module. \item[{\em ulTimer}]specifies the timer; must be one of {\bfseries TIMER\_\-A} or {\bfseries TIMER\_\-B}. Only {\bfseries TIMER\_\-A} should be used when the timer is configured for 32-\/bit operation.\end{DoxyParams}
This function gets the currently programmed interval load value for the specified timer.

\begin{DoxyReturn}{Returns}
Returns the load value for the timer. 
\end{DoxyReturn}
\hypertarget{group__timer__api_ga44faa8d49da187e7b17f960c7078403e}{
\index{timer\_\-api@{timer\_\-api}!TimerLoadSet@{TimerLoadSet}}
\index{TimerLoadSet@{TimerLoadSet}!timer_api@{timer\_\-api}}
\subsubsection[{TimerLoadSet}]{\setlength{\rightskip}{0pt plus 5cm}void TimerLoadSet (
\begin{DoxyParamCaption}
\item[{unsigned long}]{ ulBase, }
\item[{unsigned long}]{ ulTimer, }
\item[{unsigned long}]{ ulValue}
\end{DoxyParamCaption}
)}}
\label{group__timer__api_ga44faa8d49da187e7b17f960c7078403e}
Sets the timer load value.


\begin{DoxyParams}{Parameters}
\item[{\em ulBase}]is the base address of the timer module. \item[{\em ulTimer}]specifies the timer(s) to adjust; must be one of {\bfseries TIMER\_\-A}, {\bfseries TIMER\_\-B}, or {\bfseries TIMER\_\-BOTH}. Only {\bfseries TIMER\_\-A} should be used when the timer is configured for 32-\/bit operation. \item[{\em ulValue}]is the load value.\end{DoxyParams}
This function sets the timer load value; if the timer is running then the value will be immediately loaded into the timer.

\begin{DoxyReturn}{Returns}
None. 
\end{DoxyReturn}
\hypertarget{group__timer__api_ga9fa5aca88900e80db7d60109d4143bb9}{
\index{timer\_\-api@{timer\_\-api}!TimerMatchGet@{TimerMatchGet}}
\index{TimerMatchGet@{TimerMatchGet}!timer_api@{timer\_\-api}}
\subsubsection[{TimerMatchGet}]{\setlength{\rightskip}{0pt plus 5cm}unsigned long TimerMatchGet (
\begin{DoxyParamCaption}
\item[{unsigned long}]{ ulBase, }
\item[{unsigned long}]{ ulTimer}
\end{DoxyParamCaption}
)}}
\label{group__timer__api_ga9fa5aca88900e80db7d60109d4143bb9}
Gets the timer match value.


\begin{DoxyParams}{Parameters}
\item[{\em ulBase}]is the base address of the timer module. \item[{\em ulTimer}]specifies the timer; must be one of {\bfseries TIMER\_\-A} or {\bfseries TIMER\_\-B}. Only {\bfseries TIMER\_\-A} should be used when the timer is configured for 32-\/bit operation.\end{DoxyParams}
This function gets the match value for the specified timer.

\begin{DoxyReturn}{Returns}
Returns the match value for the timer. 
\end{DoxyReturn}
\hypertarget{group__timer__api_gaa3700e1bbef47e74a755371190223a39}{
\index{timer\_\-api@{timer\_\-api}!TimerMatchSet@{TimerMatchSet}}
\index{TimerMatchSet@{TimerMatchSet}!timer_api@{timer\_\-api}}
\subsubsection[{TimerMatchSet}]{\setlength{\rightskip}{0pt plus 5cm}void TimerMatchSet (
\begin{DoxyParamCaption}
\item[{unsigned long}]{ ulBase, }
\item[{unsigned long}]{ ulTimer, }
\item[{unsigned long}]{ ulValue}
\end{DoxyParamCaption}
)}}
\label{group__timer__api_gaa3700e1bbef47e74a755371190223a39}
Sets the timer match value.


\begin{DoxyParams}{Parameters}
\item[{\em ulBase}]is the base address of the timer module. \item[{\em ulTimer}]specifies the timer(s) to adjust; must be one of {\bfseries TIMER\_\-A}, {\bfseries TIMER\_\-B}, or {\bfseries TIMER\_\-BOTH}. Only {\bfseries TIMER\_\-A} should be used when the timer is configured for 32-\/bit operation. \item[{\em ulValue}]is the match value.\end{DoxyParams}
This function sets the match value for a timer. This is used in capture count mode to determine when to interrupt the processor and in PWM mode to determine the duty cycle of the output signal.

\begin{DoxyReturn}{Returns}
None. 
\end{DoxyReturn}
\hypertarget{group__timer__api_ga6ccd45b12141c58c580ebdf3f5a2d3df}{
\index{timer\_\-api@{timer\_\-api}!TimerPrescaleGet@{TimerPrescaleGet}}
\index{TimerPrescaleGet@{TimerPrescaleGet}!timer_api@{timer\_\-api}}
\subsubsection[{TimerPrescaleGet}]{\setlength{\rightskip}{0pt plus 5cm}unsigned long TimerPrescaleGet (
\begin{DoxyParamCaption}
\item[{unsigned long}]{ ulBase, }
\item[{unsigned long}]{ ulTimer}
\end{DoxyParamCaption}
)}}
\label{group__timer__api_ga6ccd45b12141c58c580ebdf3f5a2d3df}
Get the timer prescale value.


\begin{DoxyParams}{Parameters}
\item[{\em ulBase}]is the base address of the timer module. \item[{\em ulTimer}]specifies the timer; must be one of {\bfseries TIMER\_\-A} or {\bfseries TIMER\_\-B}.\end{DoxyParams}
This function gets the value of the input clock prescaler. The prescaler is only operational when in 16-\/bit mode and is used to extend the range of the 16-\/bit timer modes.

\begin{DoxyReturn}{Returns}
The value of the timer prescaler. 
\end{DoxyReturn}
\hypertarget{group__timer__api_ga7cf851124da7d14993aad51ce89b3a70}{
\index{timer\_\-api@{timer\_\-api}!TimerPrescaleSet@{TimerPrescaleSet}}
\index{TimerPrescaleSet@{TimerPrescaleSet}!timer_api@{timer\_\-api}}
\subsubsection[{TimerPrescaleSet}]{\setlength{\rightskip}{0pt plus 5cm}void TimerPrescaleSet (
\begin{DoxyParamCaption}
\item[{unsigned long}]{ ulBase, }
\item[{unsigned long}]{ ulTimer, }
\item[{unsigned long}]{ ulValue}
\end{DoxyParamCaption}
)}}
\label{group__timer__api_ga7cf851124da7d14993aad51ce89b3a70}
Set the timer prescale value.


\begin{DoxyParams}{Parameters}
\item[{\em ulBase}]is the base address of the timer module. \item[{\em ulTimer}]specifies the timer(s) to adjust; must be one of {\bfseries TIMER\_\-A}, {\bfseries TIMER\_\-B}, or {\bfseries TIMER\_\-BOTH}. \item[{\em ulValue}]is the timer prescale value; must be between 0 and 255, inclusive.\end{DoxyParams}
This function sets the value of the input clock prescaler. The prescaler is only operational when in 16-\/bit mode and is used to extend the range of the 16-\/bit timer modes.

\begin{DoxyReturn}{Returns}
None. 
\end{DoxyReturn}
\hypertarget{group__timer__api_ga0026845c00f07517b05c37638f835731}{
\index{timer\_\-api@{timer\_\-api}!TimerRTCDisable@{TimerRTCDisable}}
\index{TimerRTCDisable@{TimerRTCDisable}!timer_api@{timer\_\-api}}
\subsubsection[{TimerRTCDisable}]{\setlength{\rightskip}{0pt plus 5cm}void TimerRTCDisable (
\begin{DoxyParamCaption}
\item[{unsigned long}]{ ulBase}
\end{DoxyParamCaption}
)}}
\label{group__timer__api_ga0026845c00f07517b05c37638f835731}
Disable RTC counting.


\begin{DoxyParams}{Parameters}
\item[{\em ulBase}]is the base address of the timer module.\end{DoxyParams}
This function causes the timer to stop counting when in RTC mode.

\begin{DoxyReturn}{Returns}
None. 
\end{DoxyReturn}
\hypertarget{group__timer__api_ga43e89e7a1ce13e8b6b33f557819749c2}{
\index{timer\_\-api@{timer\_\-api}!TimerRTCEnable@{TimerRTCEnable}}
\index{TimerRTCEnable@{TimerRTCEnable}!timer_api@{timer\_\-api}}
\subsubsection[{TimerRTCEnable}]{\setlength{\rightskip}{0pt plus 5cm}void TimerRTCEnable (
\begin{DoxyParamCaption}
\item[{unsigned long}]{ ulBase}
\end{DoxyParamCaption}
)}}
\label{group__timer__api_ga43e89e7a1ce13e8b6b33f557819749c2}
Enable RTC counting.


\begin{DoxyParams}{Parameters}
\item[{\em ulBase}]is the base address of the timer module.\end{DoxyParams}
This function causes the timer to start counting when in RTC mode. If not configured for RTC mode, this will do nothing.

\begin{DoxyReturn}{Returns}
None. 
\end{DoxyReturn}
\hypertarget{group__timer__api_ga6c5cb6601369fdd2a03b5b63699ade8d}{
\index{timer\_\-api@{timer\_\-api}!TimerValueGet@{TimerValueGet}}
\index{TimerValueGet@{TimerValueGet}!timer_api@{timer\_\-api}}
\subsubsection[{TimerValueGet}]{\setlength{\rightskip}{0pt plus 5cm}unsigned long TimerValueGet (
\begin{DoxyParamCaption}
\item[{unsigned long}]{ ulBase, }
\item[{unsigned long}]{ ulTimer}
\end{DoxyParamCaption}
)}}
\label{group__timer__api_ga6c5cb6601369fdd2a03b5b63699ade8d}
Gets the current timer value.


\begin{DoxyParams}{Parameters}
\item[{\em ulBase}]is the base address of the timer module. \item[{\em ulTimer}]specifies the timer; must be one of {\bfseries TIMER\_\-A} or {\bfseries TIMER\_\-B}. Only {\bfseries TIMER\_\-A} should be used when the timer is configured for 32-\/bit operation.\end{DoxyParams}
This function reads the current value of the specified timer.

\begin{DoxyReturn}{Returns}
Returns the current value of the timer. 
\end{DoxyReturn}
